<?php

namespace app\controller\index;

use app\result\StatisticResult;
use think\App;

class Statistic extends BaseIndex
{
    public function __construct(App $app)
    {
        parent::__construct($app);
        $this->objResult = new  StatisticResult();
    }

    //按类型统计
    public function type()
    {
        data_exit_json($this->objResult->get_user_statistic($this->user_id, $this->param));
    }

    public function table_list()
    {
        data_exit_json($this->objResult->table_list($this->user_id, $this->param));
    }

    public function setting_set()
    {
        data_exit_json($this->objResult->setting_set($this->user_id, $this->param));
    }

    public function setting_get()
    {
        data_exit_json($this->objResult->setting_get($this->user_id));
    }

    public function calendar()
    {
        data_exit_json($this->objResult->calendar($this->user_id, $this->param));
    }
}
